<%@ page import="com.hsh.bean.Blog" %><%--
  Created by IntelliJ IDEA.
  User: 黄斯灏
  Date: 2020/11/18
  Time: 16:26
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <script src="js/jquery-1.8.0.min.js"></script>
    <script>
        $(function () {
            $("#favor").click(function () {
                var bid = ${blog.getBid()};
                $.post("/clickFavor", "bid="+bid ,function (result) {
                    alert('post提交：bid：,'+bid);
                    $("#favorNum").html(result);
                });
            });
        });
    </script>
    <title>微博点赞</title>
</head>
<body>
    <div>${blog.getNickname()}</div>
    <div>${blog.getBlogText()}</div>
    <div id="favor">点赞：
        <span id="favorNum">${blog.getFavor()}</span>
    </div>
</body>
</html>
